package es.uji.viselab.robot;

public class RobotAnswer {
    
	String completeText;
	String text[] = new String[9];
	Integer value[] = new Integer[9];
	int quantity;
	
	public RobotAnswer(String textAnswer) {
		completeText=textAnswer;
		text = textAnswer.split(" ");		
        quantity=text.length;
        for (int i=1;i<=quantity;i++){
        	try {
        	 value[i-1]=Integer.parseInt(text[i-1]);
        	} catch (Exception e){
        	  value[i-1]=-1;
            }
        }
        
	}

	public Integer getVal(int i) {
		return value[i-1];
	}

	public String getText() {
		return completeText;
	}

}
